<!DOCTYPE html>
<html lang="en">
	<head>
		<meta charset="utf-8" />
		<title>苏南采购系统</title>
		<link rel="shortcut icon" href="${basePath}/static/style/images/favicon.ico" type="image/x-icon" />
		<meta name="description" content="User login page" />
		<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0" />
		<!-- bootstrap & fontawesome -->
		<link rel="stylesheet" href="${basePath}/static/assets/css/bootstrap.css" />
		<link rel="stylesheet" href="${basePath}/static/assets/css/font-awesome.css" />
		<script src='${basePath}/static/assets/js/jquery.js'></script>
		<script type="text/javascript">
			$(function(){
				if(self != top){
					var url = window.location.href;
					parent.window.location.href=url;
				}
			});
		</script>
		<!-- text fonts -->
		<link rel="stylesheet" href="${basePath}/static/assets/css/ace-fonts.css" />

		<!-- ace styles -->
		<link rel="stylesheet" href="${basePath}/static/assets/css/ace.css" />
		<link rel="stylesheet" href="${basePath}/static/assets/css/ace-rtl.css" />
		<script src="${basePath}/static/layer/layer.js"></script>		
		<script src="${basePath}/static/blade/js/blade-ajax.js" type="text/javascript" ></script>

		<style>
			body{
				background:url(/static/blade/img/login_b.jpg)no-repeat;
				width:100%;
				height:100%;
				background-size:100% 100%;
				position:absolute;
				filter:progid:DXImageTransform.Microsoft.AlphaImageLoader(src='bg-login.png',sizingMethod='scale');

			}
			.main{
				width: 100%;
				height: 100%;
			}
			.main .user{
				width: 300px;
				margin: 0 auto;

			}

			.topbank{
				height: 35%;

			}
			.btnsss{
				background-color: #009999;
				color:white;
				width: 60px;
				height: 25px;
			}
			.but{
				text-align: center;
				margin-top: 3%;
				padding-right: 3%;
			}



		</style>
	</head>

	<body>
	<!--<form method="post" action="${basePath}/doLogin" id="loginform">-->
		<div class="main">
			<div class="topbank">
				<span style="display: block;height: 25%"></span>
			</div>
			<div class="user">
				<span style="color: white;">帐&nbsp;&nbsp;&nbsp;&nbsp;号：</span>
				<input type="text"  id="account"  value="">
			</div>
			<div class="user">
				<div style="margin-top: 5%">
					<span style="color: white;">密&nbsp;&nbsp;&nbsp;&nbsp;码：</span>
					<input type="password"   id="password"   value="">
				</div>

			</div>

			<div class="but">
				<button type="submit" onclick="doLogin()" class="btnsss">
					登录
				</button>
			</div>

		</div>
	<!--</form>-->
		<!--<div class="main-container">-->
			<!--<div class="main-content">-->
				<!--<div class="row">-->
					<!--<div class="col-sm-10 col-sm-offset-1">-->
						<!--<div class="login-container">-->
							<!--<div class="center">-->
								<!--<h1>-->
									<!--<span class="blue">苏南采购系统</span>-->
								<!--</h1>-->
							<!--</div>-->
							<!--<br>-->
							<!--<div class="space-6"></div>-->

							<!--<div class="position-relative">-->
								<!--<div id="login-box" class="login-box visible widget-box no-border">-->
									<!--<div class="widget-body">-->
										<!--<div class="widget-main">-->
											<!--<h4 class="header blue lighter bigger">-->
												<!--<i class="ace-icon fa fa-coffee blue"></i>-->
												<!--请登录-->
											<!--</h4>-->

											<!--<div class="space-6"></div>-->

											<!--<form method="post" data-imgcode="imgcode" action="${basePath}/doLogin" id="loginform">-->
												<!--<div class="input-group input-group-sx">-->
														<!--<span class="input-group-addon">-->
															<!--<i class="fa fa-user" style="width:15px;"></i>-->
														<!--</span>-->
														<!--<input type="text" name="account" class="form-control" placeholder="账号">-->
												<!--</div>-->
												<!--<br>-->
												<!--<div class="input-group input-group-sx">-->
														<!--<span class="input-group-addon">-->
															<!--<i class="fa fa-unlock-alt" style="width:15px;"></i>-->
														<!--</span>-->
														<!--<input type="password" name="password" class="form-control" placeholder="密码">-->
												<!--</div>-->
												<!--<br>-->
												<!--<div class="input-group input-group-sx">-->
														<!--<span class="input-group-addon">-->
															<!--<i class="fa fa-picture-o" style="width:15px;"></i>-->
														<!--</span>-->
														<!--<input type="text" name="imgCode" class="form-control" placeholder="验证码">-->
												<!---->
														<!--<span class="input-group-btn">-->
															<!--<img id="imgcode" src="${basePath}/captcha" onclick="this.src = '${basePath}/captcha?v=' + Math.random()" height="34" style="border: 1px solid #ccc;border-left: 0;cursor: pointer;" />-->
														<!--</span>-->
												<!---->
												<!--</div>-->
												<!--<br>-->
												<!--<div class="clearfix">-->
														<!--<button type="reset" class="width-30 pull-left btn btn-sm btn-info">-->
															<!--<i class="ace-icon fa fa-refresh"></i>-->
															<!--<span class="bigger-110">重置</span>-->
														<!--</button>-->

														<!--<button type="submit" class="width-65 pull-right btn btn-sm btn-primary">-->
															<!--<span class="bigger-110">登录</span>-->

															<!--<i class="ace-icon fa fa-arrow-right icon-on-right"></i>-->
														<!--</button>-->
													<!--</div>-->
											<!--</form>-->

										<!--</div>&lt;!&ndash; /.widget-main &ndash;&gt;-->

										<!--<div class="toolbar clearfix" style="text-align: center;margin:0 auto;">-->
                                            <!--<div style="float:none;text-align: center;font-size: 16px;color: white;">-->
                                                <!--2016<a target="_blank" href="http://ikkong.com" style="color:white;text-decoration: none;">&copy; IKKONG</a>-->
                                            <!--</div>-->
										<!--</div>-->
									<!--</div>&lt;!&ndash; /.widget-body &ndash;&gt;-->
								<!--</div>&lt;!&ndash; /.login-box &ndash;&gt;-->
							<!--</div>&lt;!&ndash; /.position-relative &ndash;&gt;-->
						<!--</div>-->
					<!--</div>&lt;!&ndash; /.col &ndash;&gt;-->
				<!--</div>&lt;!&ndash; /.row &ndash;&gt;-->
			<!--</div>&lt;!&ndash; /.main-content &ndash;&gt;-->
		<!--</div>&lt;!&ndash; /.main-container &ndash;&gt;-->

		<!-- basic scripts -->

		<!--[if !IE]> -->
		<script type="text/javascript">
			window.jQuery || document.write("<script src='${basePath}/static/assets/js/jquery.js'>"+"<"+"/script>");
		</script>

		<!-- <![endif]-->

		<!--[if IE]>
		<script type="text/javascript">
		 window.jQuery || document.write("<script src='${basePath}/static/assets/js/jquery1x.js'>"+"<"+"/script>");
		</script>
		<![endif]-->
		<script type="text/javascript">
			if('ontouchstart' in document.documentElement) document.write("<script src='${basePath}/static/assets/js/jquery.mobile.custom.js'>"+"<"+"/script>");
		</script>

		<!-- inline scripts related to this page -->
		<script type="text/javascript">
			doLogin = function(){
                $.post("/doLogin",{account:$("#account").val(),password:$("#password").val()},function (data) {
                    if (data.code === 0) {
                        			layer.msg(data.message, {shift: 1});
                        			setTimeout(function(){window.location.href = "${basePath}/";}, 1200);
                        			return false;
                        		} else {
                        			layer.msg(data.message, {shift: 6});
                        			$imgcode.click();
                        			return false;
                        		}
                });
			}
			$(function(){
				// $("form").submit(function(){
				// 	var $form = $(this);
				// 	var $imgcode=$("#"+$form.attr("data-imgcode"));
				//
				// 	var ajax = new $ax($form.attr("action"), function(data){
				// 		if (data.code === 0) {
				// 			layer.msg(data.message, {shift: 1});
				// 			setTimeout(function(){window.location.href = "${basePath}/";}, 1200);
				// 			return false;
				// 		} else {
				// 			layer.msg(data.message, {shift: 6});
				// 			$imgcode.click();
				// 			return false;
				// 		}
				// 	});
				// 	ajax.data = $form.serialize();
				// 	ajax.start();
				//
				// 	return false;
				// });
				 $(document).on('click', '.toolbar a[data-target]', function(e) {
						e.preventDefault();
						var target = $(this).data('target');
						$('.widget-box.visible').removeClass('visible');//hide others
						$(target).addClass('visible');//show target
				 });
			});
			
			
		</script>
	</body>
</html>



